import{d as i,e as n,a as r,P as p,Q as m,R as e,$ as t,X as _,a2 as g,a5 as h,a8 as v,a9 as b,a4 as x}from"./elementPlusModules.js";import{_ as f}from"./index.js";import"./lodashModules.js";import"./vxeTableModules.js";const o=a=>(v("data-v-9f4ab34a"),a=a(),b(),a),u={class:"demo-image__placeholder"},k={class:"block"},y=o(()=>e("span",{class:"demonstration"},"Default",-1)),w={class:"block"},j=o(()=>e("span",{class:"demonstration"},"Custom",-1)),C=o(()=>e("div",{class:"image-slot"},[x("Loading"),e("span",{class:"dot"},"...")],-1)),l="https://cube.elemecdn.com/6/94/4d3ea53c084bad6931a56d5158a48jpeg.jpeg",I=i({__name:"Placeholder",setup(a){const c=n(`
<template>
  <div class="demo-image__placeholder">
    <div class="block">
      <span class="demonstration">Default</span>
      <el-image :src="src" />
    </div>
    <div class="block">
      <span class="demonstration">Custom</span>
      <el-image :src="src">
        <template #placeholder>
          <div class="image-slot">Loading<span class="dot">...</span></div>
        </template>
      </el-image>
    </div>
  </div>
</template>

<script lang="ts" setup>
const src =
  'https://cube.elemecdn.com/6/94/4d3ea53c084bad6931a56d5158a48jpeg.jpeg'
<\/script>

<style scoped>
.demo-image__placeholder .block {
  padding: 30px 0;
  text-align: center;
  border-right: solid 1px var(--el-border-color);
  display: inline-block;
  width: 49%;
  box-sizing: border-box;
  vertical-align: top;
}
.demo-image__placeholder .demonstration {
  display: block;
  color: var(--el-text-color-secondary);
  font-size: 14px;
  margin-bottom: 20px;
}
.demo-image__placeholder .el-image {
  padding: 0 5px;
  max-width: 300px;
  max-height: 200px;
}

.demo-image__placeholder.image-slot {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  height: 100%;
  background: var(--el-fill-color-light);
  color: var(--el-text-color-secondary);
  font-size: 14px;
}
.demo-image__placeholder .dot {
  animation: dot 2s infinite steps(3, start);
  overflow: hidden;
}
</style>
`);return(d,S)=>{const s=r("el-image");return p(),m(h,null,[e("div",u,[e("div",k,[y,t(s,{src:l})]),e("div",w,[j,t(s,{src:l},{placeholder:_(()=>[C]),_:1})])]),g(d.$slots,"default",{html:c.value},void 0,!0)],64)}}}),V=f(I,[["__scopeId","data-v-9f4ab34a"]]);export{V as default};
